/*
 * @Author: your name
 * @Date: 2022-04-06 10:06:13
 * @LastEditTime: 2022-07-16 16:37:04
 * @LastEditors: YNT 2501512800@qq.com
 * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 * @FilePath: \22-03-19 智慧社区\api\repair.js
 */
import wxRequest from '../utils/wx-request'

class SpecialModel extends wxRequest {
  // 报事报修列表
  repairList() {
    return this.request({
      url: `/api/v1/report_repair/list`,
      method: 'GET',
    })
  }

  // 保修详情
  repairDetail(id) {
    return this.request({
      url: `/api/v1/report_repair?id=${id}`,
      method: 'GET',
    })
  }

  // 报修分类
  repairType() {
    return this.request({
      url: `/api/v1/report_repair/type`,
      method: 'GET',
    })
  }

  // 报修上报
  repairUpload(data) {
    return this.request({
      url: `/api/v1/report_repair`,
      method: 'POST',
      data,
    })
  }
}

export default new SpecialModel()
